package spring.boot.btc.schedule;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;
import spring.boot.btc.service.BlockReceiveService;

@Component
public class BroadcastReceiveJob {

    @Autowired
    private BlockReceiveService blockReceiveService;

    @Scheduled(cron = "*/1 * * * * ?")
    public void receive() {
        blockReceiveService.receive();
    }



    @Scheduled(cron = "*/1 * * * * ?")
    public void receiveMoney() {
        blockReceiveService.receiveMoney();
    }

}
